/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.evote.monitoreo.entity;

import java.io.Serializable;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Lob;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 *
 * @author Mendoza
 */
@Entity
@Table(name = "diccionariolog", catalog = "evote", schema = "")
@NamedQueries({
    @NamedQuery(name = "Diccionariolog.findAll", query = "SELECT d FROM Diccionariolog d"),
    @NamedQuery(name = "Diccionariolog.findByIdDiccionarioLog", query = "SELECT d FROM Diccionariolog d WHERE d.idDiccionarioLog = :idDiccionarioLog")})
public class Diccionariolog implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "idDiccionarioLog", nullable = false)
    private Integer idDiccionarioLog;
    @Lob
    @Column(name = "descripcion", length = 65535)
    private String descripcion;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "diccionarioLogidDiccionarioLog")
    private List<Logusuario> logusuarioList;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "diccionarioLogidDiccionarioLog")
    private List<Logelector> logelectorList;

    public Diccionariolog() {
    }

    public Diccionariolog(Integer idDiccionarioLog) {
        this.idDiccionarioLog = idDiccionarioLog;
    }

    public Integer getIdDiccionarioLog() {
        return idDiccionarioLog;
    }

    public void setIdDiccionarioLog(Integer idDiccionarioLog) {
        this.idDiccionarioLog = idDiccionarioLog;
    }

    public String getDescripcion() {
        return descripcion;
    }

    public void setDescripcion(String descripcion) {
        this.descripcion = descripcion;
    }

    public List<Logusuario> getLogusuarioList() {
        return logusuarioList;
    }

    public void setLogusuarioList(List<Logusuario> logusuarioList) {
        this.logusuarioList = logusuarioList;
    }

    public List<Logelector> getLogelectorList() {
        return logelectorList;
    }

    public void setLogelectorList(List<Logelector> logelectorList) {
        this.logelectorList = logelectorList;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (idDiccionarioLog != null ? idDiccionarioLog.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Diccionariolog)) {
            return false;
        }
        Diccionariolog other = (Diccionariolog) object;
        if ((this.idDiccionarioLog == null && other.idDiccionarioLog != null) || (this.idDiccionarioLog != null && !this.idDiccionarioLog.equals(other.idDiccionarioLog))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.evote.monitoreo.entity.Diccionariolog[idDiccionarioLog=" + idDiccionarioLog + "]";
    }

}
